<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2017/9/29 0029
 * Time: 14:25
 */

namespace Cuke\Services;


use Phalcon\Mvc\User\Component;

class ServiceBase extends Component
{
    /**
     * @var static
     */
    protected static $instance=null;
    /**
     * 单例
     * @return static
     */
    public static function getInstance()
    {
        if(empty(static::$instance)){
            static::$instance=new static();
        }
        return static::$instance;
    }
}